package com.bsoft.gol.hcs.satisfyStatic.dao;

import ctd.persistence.annotation.DAOMethod;
import ctd.persistence.annotation.DAOParam;
import ctd.persistence.support.hibernate.HibernateSupportDelegateDAO;
import com.bsoft.gol.hcs.satisfyStatic.entity.OdsSatisfyStatisticExtraDetail;

import java.util.List;

/**
 * Created by ChenJij on 2022/7/26.
 */
public abstract class OdsSatisfyStatisticExtraDetailDAO extends HibernateSupportDelegateDAO<OdsSatisfyStatisticExtraDetail> {
    public OdsSatisfyStatisticExtraDetailDAO() {
        this.setKeyField("extraDetailId");
    }

    @DAOMethod(sql = " delete from OdsSatisfyStatisticExtraDetail where settingId=:settingId ")
    public abstract void deleteAllBySettingId(@DAOParam("settingId") String settingId);


    @DAOMethod(sql = "from OdsSatisfyStatisticExtraDetail where statisticExtraId=:statisticExtraId  order by sort asc")
    public abstract List<OdsSatisfyStatisticExtraDetail> queryByStatisticExtraId(@DAOParam("statisticExtraId") String statisticExtraId);


    @DAOMethod(sql = "select titleId from OdsSatisfyStatisticExtraDetail where statisticExtraId=:statisticExtraId ")
    public abstract List<String> queryTitleIdListByStatisticExtraId(@DAOParam("statisticExtraId") String statisticExtraId);
}